@mars-basecolor: #ffffffd9; // 基础字体颜色
@mars-basecolor-reverse: #000; // 基础字体颜色-反色
@primary-color: #4db3ff; // 主要颜色
@mars-ordinary-color: rgba(32, 160, 255, 0.2); // 普通颜色
@mars-background-active: #000000d9; // 全局激活背景色
@font-size-base: 12px; // 主要字体大小
@border-color-ordinary: grey; // 基础边框颜色
@border-color-base: #ececec; // 基础边框颜色
@tree-border-color: #ccc; //树控件复选框边框颜色
@mars-disable-color: #ccc; // 禁用字体颜色
@form-input-background: rgba(63, 72, 84, 0.7); // input 背景色
@input-background-active: rgba(37, 49, 63, 0.788); // input 激活背景色
@background-base: #14141480; // 基础背景色
@button-background-base: #20a0ff33; // 按钮背景
@button-color-base: #ffffff; // 按钮字体颜色
@button-color-active: #ffffff; // 按钮激活字体颜色
@button-background-active: #20a0ff33; // 按钮激活背景颜色
@collapse-header-color: #202a4480; // 折叠面板头部颜色

.mars-main-view {
  color: @mars-basecolor;
  // collapse 折叠面板相关样式
  .ant-collapse,
  .ant-collapse-item,
  .ant-collapse-content {
    background: none !important;
    border: none;
  }
  .ant-collapse-content-box {
    padding: 5px;
  }

  .ant-collapse-header {
    background-color: @collapse-header-color !important;
    padding: 5px 10px !important;
    border-bottom: 1px solid @mars-basecolor-reverse;
    color: #fff !important;
    .i-icon {
      font-size: 16px !important;
      line-height: 16px;
      vertical-align: middle !important;
    }
  }
  .ant-collapse-content {
    color: @mars-basecolor !important;
  }

  .ant-collapse-extra {
    .i-icon {
      font-size: 16px;
      line-height: 16px;
      vertical-align: middle;
    }
  }

  // 切换按钮
  .ant-radio-button-wrapper {
    background: rgba(32, 160, 255, 0.2);
    color: @mars-basecolor;
    box-shadow: none !important;
  }

  // 表单元素
  .ant-form {
    color: rgba(255, 255, 255, 0.925);
  }
  .ant-form-item {
    margin-bottom: 10px !important;
    color: @mars-basecolor;
    .ant-form-item-label > label {
      color: @mars-basecolor;
    }
  }
  .ant-form-item:nth-last-child(1) {
    margin-bottom: 0 !important;
  }

  /* 卡片 */
  .mars-ant-card {
    background: none;
    border: 1px solid @mars-basecolor;
    color: @mars-basecolor;
    .ant-card-head {
      border-color: @mars-basecolor;
      min-height: auto;
      padding: 0 10px;
      color: white;
      .ant-card-head-title {
        padding: 8px 0;
      }
    }
    .ant-card-body {
      padding: 10px;
    }
  }

  // 文件选择
  .ant-upload {
    color: @mars-basecolor;
  }

  // 多选
  // .ant-checkbox{
  //   background-color: #fff;
  // }
  .ant-checkbox-wrapper {
    color: @mars-basecolor;
    .ant-checkbox-inner {
      background-color: #fff;
      border-color: @border-color-ordinary;
    }
    .ant-checkbox-checked {
      background: @primary-color;
      .ant-checkbox-inner {
        background-color: @primary-color;
        border-color: @primary-color;
      }
    }
  }

  // 单选
  .ant-radio-wrapper {
    color: @mars-basecolor;
    .ant-radio-inner {
      background-color: #fff;
      border-color: @border-color-ordinary;
      box-shadow: none !important;
      outline: none !important;
    }
    .ant-radio-checked {
      .ant-radio-inner {
        border-color: @primary-color;
      }
    }
    .ant-radio-input {
      box-shadow: none !important;
      outline: none !important;
    }
  }

  // 开关
  .ant-switch {
    background-color: hsla(0, 0%, 100%, 0.3);
  }
  .ant-switch-checked {
    background-color: #4db3ff !important;
  }

  // 表格
  .ant-table,
  .ant-table-thead > tr > th {
    color: @mars-basecolor;
    background: none !important;
  }
  .ant-table .ant-table-thead {
    background-color: rgba(32, 160, 255, 0.2);
  }
  .ant-table-tbody > tr.ant-table-placeholder > td {
    background: #141414;
  }
  .ant-table-row:hover > td,
  .ant-table-row-selected > td {
    background-color: @mars-ordinary-color !important;
  }

  .ant-table-container,
  .ant-table-cell {
    border-color: #cde1de !important;
    background: transparent !important;
  }
  .ant-table-container {
    border: 1px solid #cde1de !important;
  }
  .ant-table-cell:last-child {
    border-right: 0 !important;
  }
  .ant-table-placeholder > td {
    background: rgba(32, 42, 68, 0.3) !important;
  }

  .ant-table-row:nth-last-child(1) .ant-table-cell {
    border-bottom: none;
  }

  :deep(.ant-tabs-tab) {
    color: @mars-basecolor !important;
  }

  // 分页
  .ant-pagination {
    * {
      color: @mars-basecolor !important;
    }
    .ant-pagination-item,
    .ant-pagination-prev,
    .ant-pagination-next {
      background: none;
      background-color: transparent !important;
    }
    .ant-pagination-simple-pager {
      input {
        background: none;
        background-color: transparent !important;
      }
    }
  }

  .ant-select-dropdown {
    background-color: @form-input-background !important;
    .ant-select-item {
      transition: none;
      &:hover,
      &:focus {
        background-color: @input-background-active;
      }
    }
    .ant-select-item-option-active {
      background-color: @input-background-active !important;
    }
  }
  .ant-select:not(.ant-select-customize-input) .ant-select-selector {
    background-color: transparent !important;
  }

  .ant-select-item-option-selected:not(.ant-select-item-option-disabled) {
    background-color: @mars-background-active !important;
  }
  // .ant-select:not(.ant-select-customize-input) .ant-select-selector {
  //   background-color: transparent !important;
  // }
  // .ant-select-dropdown {
  //   background-color: transparent !important;
  // }
  .ant-select-arrow {
    color: @mars-basecolor !important;
  }

  // 列表
  .ant-list-items {
    * {
      color: @mars-basecolor;
    }
    .ant-list-item {
      border-bottom: 1px solid #303030;
    }
    .ant-list-item-meta-description {
      color: hsla(0, 0%, 100%, 0.45);
    }
  }

  // 分割线
  .ant-divider-vertical {
    border-color: @mars-basecolor;
  }
}

//树控件被选中
.ant-tree .ant-tree-node-content-wrapper.ant-tree-node-selected {
  background-color: @form-input-background !important;
}

//数组输入
.ant-input-number-handler-wrap {
  background-color: @form-input-background !important;
}

//table表格滚动条
.ant-table-body {
  &::-webkit-scrollbar {
    //整体样式
    height: 0;
    width: 0;
  }
}
